package com.subfg.common.entity.common;

import com.subfg.common.util.common.TimeUtil;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;


@Data
@AllArgsConstructor
@NoArgsConstructor
@ApiModel(value = "公共请求参数")
public class CommonHeadModel {
    @ApiModelProperty(value = "系统版本", required = true, example = "test2.0")
    private String osVersion;
    @ApiModelProperty(value = "软件版本", required = true, example = "test2.0")
    private String appVersion;
    @ApiModelProperty(value = "app包名", required = true, example = "com.subfg.api")
    private String pageName;
    @ApiModelProperty(value = "设备操作系统  [WebPC, iOS, Android, Applet, WebH5]", required = true , example = "Web")
    private String osType;
    @ApiModelProperty(value = "客户端请求时间", required = true, example = "1698118159")
    private Long currentTime;
    @ApiModelProperty(value = "设备id", required = true, example = "ttfo1234125312325")
    private String deviceId;
    @ApiModelProperty(value = "用户id", example = "UI134386728117993472")
    private String userId;





    // 远程调用时, 默认给公共参数赋值
    public CommonHeadModel(String pageName) {
        this.osType = "Server";
        this.currentTime = TimeUtil.getCurrentTime();
        this.pageName = pageName;
    }
}
